/** @file cardtest2.c
*   @brief Village card test
*/

#include "dominion.h"
#include "dominion_helpers.h"
#include <assert.h>
#include <stdio.h>
#include <limits.h>

int main(int argc, char **argv)
{
    // Village card effects: +1 card, +2 actions

    printf("Running tests for village card.\n");

    int nPlayers = 2;
    int k[]      = {adventurer,
                    council_room,
                    feast,
                    gardens,
                    mine,
                    remodel,
                    smithy,
                    village,
                    baron,
                    great_hall
                   };
    int seed = 2;
    struct gameState g1;

    initializeGame(nPlayers, k, seed, &g1);

    int player  = 0;
    int card    = village;
    int choice1 = 0;
    int choice2 = 0;
    int choice3 = 0;
    int handPos = 0;
    int bonus   = 0;
    int pre_cards = g1.handCount[player];
    int pre_actions = g1.numActions;
    int added_cards = 0; // Add 1 card to hand, discard palyed card for a net gain of 0


    cardEffect(card, choice1, choice2, choice3, &g1, handPos, &bonus);
    assert (g1.handCount[player] == pre_cards + added_cards);
    assert (g1.numActions == pre_actions + 2);


    printf("Tests passed for village card.\n");

}

